package com.ebei.platform.mapper;

import java.util.List;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.pagination.Pagination;
import com.ebei.platform.entity.User;
import com.ebei.platform.vo.UserParams;
import org.apache.ibatis.annotations.Select;

import com.baomidou.mybatisplus.annotations.SqlParser;

public interface UserMapper extends BaseMapper<User> {

    /**
     * 自定义注入方法
     */
    int deleteAll();

    /**
     * 注解 @SqlParser(filter = true) 过滤多租户解析
     */
    @SqlParser(filter = true)
    @Select("select id, name from user")
    List<User> selectListBySQL();
    
    User selectByAccount(String account);
    
    User selectOne(String userId);
    
    int insertUser(User user);
    
    int updateUser(User user);
    
    List<User> selectPage(Pagination page, UserParams params);

}